// JavaScript Document


function page_load()
{
	var pid=UrlParm.parm('parent_id');
	var sql="select * from acc_rechg "; //where promoter='$uid$$'
	if(pid)
	 sql=sql.replace("$uid$$",pid);
	 if(pid==0) //admin
	    sql="select * from acc_rechg limit 200";
	 
	var orm=new atiOrmV4();
		orm.obj=sql ;
		orm.metaParam="$utype=agent";
	orm.callbackFun=function(data)
	{
		
			try{
			  processJavaEx_V2q315(data);
		   }catch(e)
		   {
			 
				 
				  showErr(e);
				  return;
		  
		   }
		   var json=str2json(data);
		  
		  var list=new TableV3("table1");
		 
			   list.bindData(json);
		   
		   
		   	
		   
	};
	orm.query();
	
	console.log("----read cook index_url:"+readCookie("index_url"));
	 $("#index_a").attr("href",readCookie("index_url"));
 
 
	
}